/**
 * 
 */
package es.ibm.santillana.mdm.postprocessing.catalog;

import com.ibm.pim.catalog.item.Item;
import com.ibm.pim.common.exceptions.PIMInvalidOperationException;
import com.ibm.pim.extensionpoints.ItemPrePostProcessingFunctionArguments;

import es.ibm.santillana.mdm.autores.Autor;

/**
 * @author Benito
 *
 */
public class AutoresPostProcessing extends CatalogGenericPostProcessing {

	public void prePostProcessing(ItemPrePostProcessingFunctionArguments arg0) {
		super.prePostProcessing(arg0);
		
		Item itmAutor = arg0.getItem();
		
		//Create displayName for this autor. ("surname[0], name")
		Autor.createDisplayName(itmAutor);
		
		//Mapped item autor in Hierarchy ABC
		try {
			Autor.mappedAutorInABC(itmAutor);
		} catch (PIMInvalidOperationException e) {
		
			e.printStackTrace();
		}
		
		
		
		super.finishPostProcessing(arg0);
	}
	
}
